import javax.swing.JOptionPane;


public class Othello {
	public static void main(String args[]){
		// Initialize models
		ModelFrameMain mFrameMain = new ModelFrameMain();
		ModelPanelGame mPanelGame = new ModelPanelGame();
		ModelPanelMenu mPanelMenu = new ModelPanelMenu();
		
		// Initialize controllers
		ControllerGame cGame = new ControllerGame();
		ControllerMenu cMenu = new ControllerMenu();
		
		// Initialize views
		ViewFrameMain vFrameMain = new ViewFrameMain();
		ViewPanelGame vPanelGame = new ViewPanelGame();
		ViewPanelMenu vPanelMenu = new ViewPanelMenu();
		
		// Add views to controllers
		cGame.addView(vFrameMain);
		cGame.addView(vPanelGame);
		
		cMenu.addView(vFrameMain);
		cMenu.addView(vPanelMenu);
		
		// Add models to controllers
		cGame.addModel(mPanelGame);
		cGame.addModel(mFrameMain);
		
		cMenu.addModel(mPanelMenu);
		cMenu.addModel(mPanelGame);		// May change in the future.
		cMenu.addModel(mFrameMain);
		
		// Tell views who is the controller
		vPanelMenu.setController(cMenu);
		vPanelGame.setController(cGame);
		
		// Initialize		
		vFrameMain.addPanel(vPanelMenu.getPanel());
		vFrameMain.addPanel(vPanelGame.getPanel());
		
		mFrameMain.setModelPanelMenu(mPanelMenu);
		mFrameMain.setModelPanelGame(mPanelGame);
		
		mFrameMain.setPanelID(0);
	}
}
